package com.hk.service.sys;

import java.math.BigInteger;
import java.util.List;

import com.hk.commons.HqlFilter;
import com.hk.commons.SqlFilter;
import com.hk.commons.entity.Customer;

public interface ICustomer {

	/** 根据id获实体 */
	public Customer findById(Long id);
	
	/** 添加 **/
	public Long add(Customer model);
	
	/**更新**/
	public void update(Customer model);

	/** 新增模块，如果模块已存在则更新 */
	public void saveOrUpdate(Customer customer);

	/** 删除 */
	public Customer delete(Long id);
	
	/** 分页获取 */
	public List<Customer> find(int pageNum, int pageSize);
	
	public List<Customer> findByFilter(HqlFilter hqlFilter);
	
	public List<Customer> findByFilter(HqlFilter hqlFilter,int pageNum, int pageSize);
	
	public Long countByFilter(HqlFilter hqlFilter);
	
	public List<Customer> findBySqlFilter(SqlFilter sqlFilter);

	public List<Customer> findBySqlFilter(SqlFilter sqlFilter, int page, int rows) ;

	public BigInteger countBySqlFilter(SqlFilter sqlFilter) ;
}
